package com.yuncheng.ccsystem.announce.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yuncheng.common.base.service.impl.BaseServiceImpl;
import com.yuncheng.ccsystem.announce.entity.CcAnnouncementSend;
import com.yuncheng.ccsystem.announce.mapper.CcAnnouncementSendMapper;
import com.yuncheng.ccsystem.announce.model.AnnouncementSendModel;
import com.yuncheng.ccsystem.announce.service.ICcAnnouncementSendService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;


@Service
public class CcAnnouncementSendServiceImpl extends BaseServiceImpl<CcAnnouncementSendMapper, CcAnnouncementSend> implements ICcAnnouncementSendService {

	@Resource
	private CcAnnouncementSendMapper ccAnnouncementSendMapper;

	@Override
	public List<String> queryByUserId(String userId) {
		return ccAnnouncementSendMapper.queryByUserId(userId);
	}

	@Override
	public Page<AnnouncementSendModel> getMyAnnouncementSendPage(Page<AnnouncementSendModel> page,
			AnnouncementSendModel announcementSendModel) {
		 return page.setRecords(ccAnnouncementSendMapper.getMyAnnouncementSendList(page, announcementSendModel));
	}

}
